package com.picket.service;

import java.util.Collection;
import java.util.List;

import org.springframework.beans.factory.annotation.Required;
import org.springframework.stereotype.Service;

import com.picket.dao.ITeamDao;
import com.picket.domain.Team;

@Service
public class TeamService implements  ITeamService{
	 
	 private ITeamDao teamDao;
	  
	 @Required
	 public void setTeamDao(
	      final ITeamDao teamDao) {
	    this.teamDao = teamDao;
	 }
	 
	 @Override
	 public void create(final List<Team> teams) {
	   teamDao.create(teams);
	 }
	 
	 @Override
	 public Collection<Team> getAllTeams() {
	  return teamDao.getAllTeams();
	 }

	@Override
	public Team getTeam(long id) {
		return teamDao.getTeam(id);
	}
	 
}
